package com.winsdom.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.winsdom.entity.Resource;
import com.winsdom.mapper.ResourceInfoMapper;
import com.winsdom.service.ResourceInfoService;
import com.winsdom.vo.ResourceInfoVO;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;
import org.springframework.util.Assert;

import java.util.List;

@Slf4j
@Service
public class ResourceInfoServiceImpl extends ServiceImpl<ResourceInfoMapper, Resource> implements ResourceInfoService {

    @Override
    public List<ResourceInfoVO> getResourceInfoByCustomerId(Long customerId) {
        log.info("查询客户已迁入的资源信息，客户ID：{}", customerId);
        Assert.notNull(customerId, "客户ID不能为空");
        return baseMapper.selectResourceInfoByCustomerId(customerId);
    }
} 